package br.com.classesinternasedatas;

import java.text.DateFormat;
import java.util.Calendar;
import java.util.Date;

public class TesteDateCalendarDateFormat {
	public static void main(String[] args) {
		Date d = new Date();
		System.out.println(d);
		Calendar c = Calendar.getInstance();
		c.setTime(d);
		c.add(Calendar.HOUR,2);
		System.out.println(d);
		Date d2 = c.getTime();
		DateFormat df = DateFormat.getInstance();
		System.out.println(df.format(d2));
	}

}
